export CXX = /usr/bin/g++

CXXFLAGS = -Ibase/ -I/usr/include/
CXXLFLAGS = -g -fPIC -lpthread 
OBJS = main.o \
	base/Service.o

.PHONY: clean

BIN = bin

all: $(BIN)

$(OBJS): %.o: %.cpp 
	$(CXX) -c $(CXXFLAGS) $< -o $@

$(BIN): $(OBJS)
	$(CXX) $(OBJS) -o $@ $(CXXLFLAGS)

clean:
	@rm -f *.o *~
	@rm -f base/*.o base/*~
	@rm -f $(BIN)

ctags:
	@ctags -R -h ".c.cpp.h" -o tags
